<template>
  <Tabs type="card">
    <TabPane label="秒杀">
      <seckill @on-select-item="handleSelect"></seckill>
    </TabPane>
    <TabPane label="团购">
      <purchase @on-select-item="handleSelect"></purchase>
    </TabPane>
  </Tabs>
</template>

<script>
import seckill from "./seckill.vue";
import purchase from "./purchase.vue";

export default {
  name: "PageSelect",
  components: { seckill, purchase },
  data() {
    return {};
  },
  props: {
    value: {
      type: Object
    }
  },
  methods: {
    handleSelect(item) {
      this.$emit("on-select-item", item);
      this.$emit("input", item);
    }
  }
};
</script>
